package com.ctshk.rpc.system.mapper;

import com.ctshk.rpc.system.base.CustomBaseMapper;
import com.ctshk.rpc.system.entity.SysSupplierOrderMsgSend;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 分配管理用户 Mapper 接口
 * </p>
 *
 * @author 姜斌文
 * @since 2021-03-31
 */
public interface SysAssignmentMgtSendMapper extends CustomBaseMapper<SysSupplierOrderMsgSend> {
    /**
     * 根据reuleId获取用户信息
     * @param ruleUserIds
     * @return List<SysSupplierOrderMsgSend>
     */
    @Select("SELECT s.id,s.rule_id,s.rule_user_id,s.user_id,s.user_name "
    		+ "FROM t_supplier_order_message_send s "
    		+ "WHERE s.rule_user_id IN (${ruleUserIds})"
    		+ "AND  s.rule_id = #{ruleId}")
    List<SysSupplierOrderMsgSend> selectSupplierOrderMsgSendByRuleId(@Param("ruleUserIds") String ruleUserIds, @Param("ruleId") Long ruleId);
}
